package org.example.POJO.game;

import org.example.Page.GamePanel;

import java.awt.*;

public class Xiang extends Chess {
    public Xiang(int camp, Point p) {
        super("xiang", camp, p);
    }
    public Xiang(int camp,int px) {
        this(camp, new Point(px, 1));
    }
    public boolean isAbleMove(Point tp, GamePanel gamePanel) {
        return isLine(tp) == 1 && getStep(tp) == 2 && !isBlock(tp, gamePanel) && !isPassRiver(tp);
    }
}
